<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="edge">
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1.0,user-scalable=0">
    <meta content="telephone=no" name="format-detection" />
    <meta name="description" content="">
    <meta name="keywords" content="">
    <title>知识库-用户中心</title>
    <link rel="stylesheet" type="text/css" href="css/reset.css">
    <link rel="stylesheet" type="text/css" href="css/global.css">
    <link rel="stylesheet" type="text/css" href="css/media.css">
    <link rel="stylesheet" type="text/css" href="css/loading.css">
    <script type="text/javascript" src="js/lib/loading.js"></script>
</head>
<body id="app">
    <!-- 头部 -->
    <header class="header" v-cloak>
        <a href="javascript:;" title="返回" class="icon back" @click="back();"></a>
        <h1>{{ user.userName }}</h1>
        <a href="javascript:void(0);" title="" class="icon addIcon" @click="add();"></a>
    </header>
    
    <section class="padT23 userHome" v-cloak>
        <div class="padTB24 vault">
            <div class="pr padB24">
                <a href="javascript:;" class="dib">
                    <img v-bind:src=user.headPic alt="" class="avatar">
                    <span class="db font18 color22 level">{{ user.level }}</span>
                </a>
            </div>
            <div class="clearfix userRecord">
                <span class="fl disableClick">{{ user.goldCount }}<br><em>白金币</em></span>
                <span :class="{'fl':true, 'disableClick':!user.collectionAbleClick}" @click="fn('collect',user.uid,user.collectionAbleClick)">{{ user.collectionCount }}<br><em>收藏</em></span>
                <span :class="{'fl':true, 'disableClick':!user.dynamicAbleClick}" @click="fn('dynamic',user.uid,user.dynamicAbleClick)"><div class="dynamicIcon"></div><em>知识动态</em></span>
            </div>
        </div>
        <!-- tab -->
        <ul class="clearfix tabUl quesTab five tabFixed">
            <li class="on" @click="slides(0,$event)">文档</li>
            <li @click="slides(1,$event)">话题</li>
            <li @click="slides(2,$event)">提问</li>
            <li @click="slides(3,$event)">回答</li>
            <li @click="slides(4,$event)">圈子</li>
        </ul>
        <div>
            <!-- 文档 -->
            <ul class="tabCont bgff quesCont tabBox" v-if="tabs==0">
                
                <li v-for="info in infos">

                    <div>
                        <a href="javascript:;" @click="toArticleDetail(info.id)" class="clearfix db">
                            <img :src="info.suffix | path" class="fileIcon" onerror="javascript:this.src='images/icon/type/OTHER.png';this.onerror=null;">
                            <div class="ques">
                                <h3 class="font26 color22 ell">{{ 
                                info.title }}</h3>
                                <span class="db font24 color21 ell">{{ info.content }}</span>
                            </div>
                        </a>
                        <template v-if="info.type.length>0">
                            <a href="meeting.html?id={{info.id}}&name={{info.name}}" class="font18 colorB tips" v-for="info in info.type"><em>{{ info.name }}</em></a>
                        </template>
                        <div class="font18 colorb6 queAuthor">
                            <span>{{ info.author }}</span>
                            <span>{{ info.score }}分</span>
                            <span>{{ info.size }}</span>
                            <span>{{ info.readCount }}阅读过</span>
                            <span>{{ info.date }}</span>
                        </div>
                    </div>
                    <div class="font26 dib shareColl two">
                        <a href="javascript:void(0);" @click="share({shareId:info.id,shareTit:info.title,sharePic:info.pic},$event);" class="shareIcon"></a>
                        <a href="javascript:void(0);" @click="doDel({dataID:info.id},$event);" class="delIcon"></a>
                    </div>
                </li>
                <span class="loading-more">加载更多...</span>
            </ul>
            <!-- 话题 -->
            <ul class="tabCont quesCont askCont" v-if="tabs==1">
                <li v-for="topic in topics">
                    <div>
                        <a href="javascript:;" @click="toCircleDetail(topic.id)" class="db">
                            <div class="clearfix padB24">
                                <img v-bind:src=topic.headPic class="fl borderRadius wh45">
                                <span class="db fl font20 color72 name">{{ topic.userName }}<em class="colorB">({{ topic.level }})</em></span>
                                <span class="fr font20 line95 colorb6">{{ topic.commentDate }}</span>
                            </div>
                            <h3 class="font26 color22 titles">{{ topic.title }}</h3>
                            <span class="db font24 color72 descText">{{ topic.content | delimages | delhtml }}</span>
                            <!-- <div class="clearfix marT24 topicImgBox">
                                <span v-for="(index, item) in topic.content | imageurls" track-by="$index">
                                    <span class="db fl j_6 topicImg" v-if="index < 4">
                                        <img data-src="{{item}}" src="images/imgload.gif" alt="" class="loadImg">
                                    </span>
                                <em class="imgNum" v-if="index >= 4">{{index + 1}}</em>
                                </span>
                            </div> -->
                            <template v-if="topic.type.length>0">
                                <a href="javascript:void(0);" class="db font18 colorB tips"><em v-for="topic in topic.type">{{ topic.name }}</em></a>
                            </template>
                            <div class="clearfix">
                                <!-- <template v-if="topic.commentPicture.length > 0">
                                <span class="fl imgIcon"></span>
                                </template> -->
                                <!-- 带精字图标的话题 -->
                                <template v-if="topic.isEssence == 1">
                                    <span class="fl jIcon"></span>
                                </template>
                                <span class="fr comIcon">{{ topic.commentCount }}</span>
                                <span class="fr view">{{ topic.readCount }}</span>
                                <!-- 如果是已点赞的，则有class="on" -->
                                <span class="fr likeIcon" v-bind:class="{'on':topic.likeCount>0}">{{ topic.likeCount }}</span>
                            </div>
                        </a>
                    </div>
                    <div class="font26 dib shareColl two">
                        <a href="javascript:void(0);" @click="share({shareId:info.id,shareTit:info.title,sharePic:info.pic},$event);" class="shareIcon"></a>
                        <a href="javascript:void(0);" @click="doDel({dataID:info.id},$event);" class="delIcon"></a>
                    </div>
                </li>
                <span class="loading-more">加载更多...</span>
            </ul>
            <!-- 提问 -->
            <!-- 提问与回答排版一致 -->
            <ul class="tabCont quesCont askCont" v-if="tabs==2">
                <li v-for="ask in asks">
                    <div>
                        <a href="javascript:;" @click="toAskDetail(ask.id)" class="db">
                            <div class="clearfix padB24">
                                <img v-bind:src=ask.headPic class="fl borderRadius wh45">
                                <span class="db fl font20 color72 name">{{ ask.userName }}<em class="colorB">({{ ask.level }})</em></span>
                                <span class="fr font20 line95 colorb6">{{ ask.commentDate }}</span>
                            </div>
                            <h3 class="font26 color22 titles">{{ ask.title }}</h3>
                            <span class="db font24 color72 descText">{{ ask.comment }}</span>
                            <template v-if="ask.type.length>0">
                                <a href="javascript:void(0);" class="db font18 colorB tips"><em v-for="ask in ask.type">{{ ask.name }}</em></a>
                            </template>
                            <div class="clearfix">
                                <span class="fl imgIcon"></span>
                                <span class="fr comIcon">{{ ask.commentCount }}</span>
                                <span class="fr view">{{ ask.readCount }}</span>
                            </div>
                        </a>
                    </div>
                    <div class="font26 dib shareColl two">
                        <a href="javascript:void(0);" @click="share({shareId:info.id,shareTit:info.title,sharePic:info.pic},$event);" class="shareIcon"></a>
                        <a href="javascript:void(0);" @click="doDel({dataID:info.id},$event);" class="delIcon"></a>
                    </div>
                </li>
                <span class="loading-more">加载更多...</span>
            </ul>
            <!-- 回答 -->
            <ul class="tabCont quesCont askCont" v-if="tabs==3">
                <li v-for="ask in asks">
                    <div>
                        <a href="javascript:;" @click="toAskDetail(ask.id)" class="db">
                            <div class="clearfix padB24">
                                <img v-bind:src=ask.headPic class="fl borderRadius wh45">
                                <span class="db fl font20 color72 name">{{ ask.userName }}<em class="colorB">({{ ask.level }})</em></span>
                                <span class="fr font20 line95 colorb6">{{ ask.commentDate }}</span>
                            </div>
                            <h3 class="font26 color22 titles">{{ ask.title }}</h3>
                            <span class="db font24 color72 descText">{{ ask.comment }}</span>
                            <template v-if="ask.type.length>0">
                                <a href="javascript:void(0);" class="db font18 colorB tips"><em v-for="ask in ask.type">{{ ask.name }}</em></a>
                            </template>
                            <div class="clearfix">
                                <span class="fl imgIcon"></span>
                                <span class="fr comIcon">{{ ask.commentCount }}</span>
                                <span class="fr view">{{ ask.readCount }}</span>
                            </div>
                        </a>
                    </div>
                    <div class="font26 dib shareColl two">
                        <a href="javascript:void(0);" @click="share({shareId:info.id,shareTit:info.title,sharePic:info.pic},$event);" class="shareIcon"></a>
                        <a href="javascript:void(0);" @click="doDel({dataID:info.id},$event);" class="delIcon"></a>
                    </div>
                </li>
                <span class="loading-more">加载更多...</span>
            </ul>
            <!-- 圈子 -->
            <ul class="tabCont quesCont myCircle" v-if="tabs==4">
                <!-- <li v-for="ask in asks">
                    <div>
                        <a href="askDetail.html?id={{ask.id}}&back=myUserCenter.html" class="db">
                            <div class="clearfix padB24">
                                <img v-bind:src=ask.headPic class="fl borderRadius wh45">
                                <span class="db fl font20 color72 name">{{ ask.userName }}<em class="colorB">({{ ask.level }})</em></span>
                                <span class="fr font20 line95 colorb6">{{ ask.commentDate }}</span>
                            </div>
                            <h3 class="font26 color22 titles">{{ ask.title }}</h3>
                            <span class="db font24 color72 descText">{{ ask.comment }}</span>
                            <template v-if="ask.type.length>0">
                                <a href="javascript:void(0);" class="db font18 colorB tips"><em v-for="ask in ask.type">{{ ask.name }}</em></a>
                            </template>
                            <div class="clearfix">
                                <span class="fl imgIcon"></span>
                                <span class="fr comIcon">{{ ask.commentCount }}</span>
                                <span class="fr view">{{ ask.readCount }}</span>
                            </div>
                        </a>
                    </div>
                    <div class="font26 dib shareColl two">
                        <a href="javascript:void(0);" @click="share({shareId:info.id,shareTit:info.title,sharePic:info.pic},$event);" class="shareIcon"></a>
                        <a href="javascript:void(0);" @click="doDel({dataID:info.id},$event);" class="delIcon"></a>
                    </div>
                </li>
                <span class="loading-more">加载更多...</span> -->
                <!-- 加入的圈子 -->
                <!-- 分类 -->
                <div class="" v-cloak>
                    <div class="padB24">
                        <ul class="clearfix circle bgff">
                            <li v-for="info in circle">
                                <a href="javascript:;" @click="toCircleList(info.id)" class="clearfix db">
                                    <span class="db j_1 photo"><img data-src="{{ info.pic }}" src="images/imgload.gif" class="loadImg" /></span>
                                    <div class="fl text">
                                        <span class="db font24 color21 ell">{{ info.name }}</span>
                                        <span class="db font18 colorb6 ell">{{ info.content }}</span>
                                    </div>
                                </a>
                            </li>
                        </ul>
                    </div>
                </div>
            </ul>
        </div>
    </section>

    <!-- 更多 -->
    <template v-if="addShow==true">
        <div class="cateBoxBg" @click="add();"></div>
        <ul class="cateBox">
            <!-- <li><a href="addLetter.html?uid={{user.uid}}">私信</a></li> -->
            <li><a href="addConsultation.html?uid={{user.uid}}">向TA咨询</a></li>
        </ul>
    </template>

    <script type="text/javascript" src="js/lib/jquery.min.js"></script>
    <script type="text/javascript" src="js/lib/vue.js"></script>
    <script src="js/lib/hammer.min.js"></script>
    <script src="js/lib/vue-touch.js"></script>
    <script type="text/javascript" src="js/lib/common.js"></script>
    <script type="text/javascript" src="js/lib/global.js"></script>
    <script type="text/javascript" src="js/lib/alert.js"></script>
    <script type="text/javascript" src="js/userCenter.js"></script>

</body>
</html>